// import Vue from 'vue';
import Constants from '../utils/constants';
import store from 'store';

function RouterAuthHook (to, from, next) {

	let user = store.get(Constants.LOGIN_USER);
	if (!user) {
		document.location = '/login.html?expiration=true';
	} else {
		next();
	}
}

export {RouterAuthHook};
